def decorator(func):
    def wrapper(*args,**kwargs):
        print("----装饰器------start")
        result=func(*args,**kwargs)
        print("----装饰器------end")
        return result
        
    return wrapper

@decorator
class TestDemo:
    def __init__(self,name,age):
        self.name=name
        self.age=age
    def func1(self,a):
        return a


if __name__=="__main__":
    print()
    test=TestDemo("张三",18)
    func=test.func1("hello")
    print(test.name,test.age)
    print(func)

